 <#import "inc/macro-page.html" as panel>
<#import "macro-filter-card-box.html" as seachpanel>
<#escape x as x?html>
<@panel.header "专业化人岗适配预警" "">
<style>
.table.content-center th,
.table.content-center td{
	text-align:center;
}
input.special-style {
	border: 0;
	background-color: #ffff0039;
	width: 100%;
}
</style>
</@panel.header>
<@panel.body>
<!-- Bread crumb -->
<div class="row page-titles">
    <div class="col-md-5 align-self-center">
        <h3>专业化人岗适配预警</h3> </div>
    <div class="col-md-7 align-self-center">
        <div class="page-nav-bar">
           <button class="btn btn-info btn-click-bind" data-sign="11">制定特定人岗适配模型</button>
           <button class="btn btn-info btn-click-bind" data-sign="12">特定人员人岗适配分析</button>
           <button class="btn btn-inverse btn-click-bind" data-sign="21" disabled>制定通用人岗适配模型</button>
           <button class="btn btn-info btn-click-bind" data-sign="22">通用人岗适配分析</button>
        </div>
    </div>
</div>
<!-- End Bread crumb -->
<!-- Container fluid  -->
<div class="container-fluid">
    <!-- Start Page Content -->
    <div class="row">
        <div class="col-7">
            <div class="card">
 				<div class="custom-card-header quick-bar">
					<div class="hint">制定通用人岗适配模型</div>
					<@seachpanel.filterbox></@seachpanel.filterbox>
					<button id="id-export-file" type="button" class="btn btn-dark btn-outline btn-sm m-l-10" title="导出"><i class="fa fa-share-square-o"></i></button>
				</div>
                 <div class="card-body">
                    <!--
                    <h4 class="card-title">特定人岗适配模型</h4>
                    <div class="row m-t-20">
                    	<div class="col-md-6 m-b-10">
                    		<select class="form-control">
                    			<option value="">请选择单位</option>
                    		</select>
                    	</div>
                    	<div class="col-md-6 m-b-10">
                    		<select class="form-control">
                    			<option value="">请选择部门</option>
                    		</select>
                    	</div>
                    	<div class="col-md-6">
                    		<select class="form-control">
                    			<option value="">请选择专业</option>
                    		</select>
                    	</div>
                    	<div class="col-md-6">
                    		<select class="form-control">
                    			<option value="">请选择岗位</option>
                    		</select>
                    	</div>
                    </div>
                    -->
					 <div class="table-responsive m-t-20">
						 <div class="scroll-box" style="height: 495px;">
							 <form id="id-model-form">
								 <table id="id-standard-table" class="table table-bordered table-cell-wrap" cellspacing="0" width="100%">
									 <thead>
									 <tr>
										 <th nowrap>标识</th>
										 <th nowrap>因子名称</th>
										 <th colspan="3" nowrap>因子说明</th>
										 <th nowrap>标准分</th>
										 <th nowrap>拟定标准</th>
									 </tr>
									 </thead>
									 <tbody>
									 <tr>
										 <td>X1</td>
										 <td>专业经历</td>
										 <td colspan="3">目标所在岗位工作年限</td>
										 <td>0.5</td>
										 <td><input disabled type="number" name="zygwgznx" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td rowspan="6">X2</td>
										 <td rowspan="6">学业经历</td>
										 <td colspan="3">博士研究生(含博士学位)/双硕士</td>
										 <td>3</td>
										 <td><input disabled type="radio" name="highEdu" value="博士研究生" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">硕士研究生</td>
										 <td>2.5</td>
										 <td><input disabled type="radio" name="highEdu" value="硕士研究生" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">双学士学位/硕士学位</td>
										 <td>2</td>
										 <td><input disabled type="radio" name="highEdu" value="双学士" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">本科(含学士学位)</td>
										 <td>1.5</td>
										 <td><input disabled type="radio" name="highEdu"  value="大学本科"/></td>
									 </tr>
									 <tr>
										 <td colspan="3">大专</td>
										 <td>1</td>
										 <td><input disabled type="radio" name="highEdu" value="大学专科" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">其他(大专以下)</td>
										 <td>0.5</td>
										 <td><input disabled type="radio" name="highEdu" value="其他" /></td>
									 </tr>
									 <!-- 以上为学历 -->
									 <tr>
										 <td rowspan="13">X3</td>
										 <td rowspan="13">任职资格</td>
										 <td rowspan="5">职称等级</td>
										 <td colspan="2">正高级</td>
										 <td>3</td>
										 <td><input disabled type="radio" name="techProfName" value="正高级" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">副高级</td>
										 <td>2.5</td>
										 <td><input disabled type="radio" name="techProfName" value="副高级" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">中级</td>
										 <td>2</td>
										 <td><input disabled type="radio" name="techProfName" value="中级" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">助理级</td>
										 <td>1</td>
										 <td><input disabled type="radio" name="techProfName" value="助理级" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">员级</td>
										 <td>0.5</td>
										 <td><input disabled type="radio" name="techProfName" value="员级" /></td>
									 </tr>
									 <!-- 以上为任职资格之职称等级 -->
									 <tr>
										 <td rowspan="5">技能等级</td>
										 <td colspan="2">高级技师</td>
										 <td>2.5</td>
										 <td><input disabled type="radio" name="profName" value="高级技师" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">技师</td>
										 <td>2</td>
										 <td><input disabled type="radio" name="profName" value="技师" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">高级工</td>
										 <td>1.5</td>
										 <td><input disabled type="radio" name="profName" value="高级工" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">中级工</td>
										 <td>1</td>
										 <td><input disabled type="radio" name="profName" value="中级工" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">初级工</td>
										 <td>0.5</td>
										 <td><input disabled type="radio" name="profName" value="初级工" /></td>
									 </tr>
									 <!-- 以上为任职资格之技能等级 -->
									 <tr>
										 <td rowspan="3">资格证书</td>
										 <td rowspan="2">社会统考资格证书</td>
										 <td>注册类</td>
										 <td>1.5</td>
										 <td><input disabled type="radio" name="shtkzgzs" value="注册类" /></td>
									 </tr>
									 <tr>
										 <td>其他</td>
										 <td>1</td>
										 <td><input disabled type="radio" name="shtkzgzs" value="其他" /></td>
									 </tr>
									 <tr>
										 <td>生产作业职业资格证书</td>
										 <td>与生产作业相关的职业资格证书</td>
										 <td>1</td>
										 <td><input disabled type="text" name="sczyzgzs" class="special-style" /></td>
									 </tr>
									 <!-- 以上为任职资格 -->
									 <tr>
										 <td rowspan="10">X4</td>
										 <td rowspan="10">绩效表现</td>
										 <td rowspan="5" colspan="2">三年绩效得分总分</td>
										 <td>6分</td>
										 <td>2</td>
										 <td><input disabled type="radio" name="snjxzf" value="6" /></td>
									 </tr>
									 <tr>
										 <td>5.5分</td>
										 <td>1.5</td>
										 <td><input disabled type="radio" name="snjxzf" value="5.5" /></td>
									 </tr>
									 <tr>
										 <td>5分</td>
										 <td>1.2</td>
										 <td><input disabled type="radio" name="snjxzf" value="5" /></td>
									 </tr>
									 <tr>
										 <td>4.5分</td>
										 <td>1</td>
										 <td><input disabled type="radio" name="snjxzf" value="4.5" /></td>
									 </tr>
									 <tr>
										 <td>4.5分以下</td>
										 <td>0.8</td>
										 <td><input disabled type="radio" name="snjxzf" value="4" /></td>
									 </tr>
									 <tr>
										 <td rowspan="4" colspan="2">三年民主测评情况</td>
										 <td>优秀</td>
										 <td>2</td>
										 <td><input disabled type="radio" name="snmzcpqk" value="优秀" /></td>
									 </tr>
									 <tr>
										 <td>称职</td>
										 <td>1</td>
										 <td><input disabled type="radio" name="snmzcpqk" value="称职" /></td>
									 </tr>
									 <tr>
										 <td>基本称职</td>
										 <td>0.5</td>
										 <td><input disabled type="radio" name="snmzcpqk" value="基本称职" /></td>
									 </tr>
									 <tr>
										 <td>不合格</td>
										 <td>-2</td>
										 <td><input disabled type="radio" name="snmzcpqk" value="不合格" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">工作表现情况</td>
										 <td>参加市公司级以上挂职锻炼、人才帮扶、劳务协作、人员借用期间表现优秀的</td>
										 <td>1</td>
										 <td><input disabled type="text" name="gzbxqk" class="special-style" /></td>
									 </tr>
									 <!-- 以上为绩效表现 -->
									 <tr>
										 <td rowspan="6">X5</td>
										 <td rowspan="6">专业成果</td>
										 <td rowspan="6">专著、研究成果数+同级竞赛、调考优秀频次</td>
										 <td rowspan="3">专著、研究成果数</td>
										 <td>国家级</td>
										 <td>-</td>
										 <td><input disabled type="number" name="yjcgsgjj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td>国网公司（省部）级</td>
										 <td>-</td>
										 <td><input disabled type="number" name="yjcgssbj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td>省公司（市）级</td>
										 <td>-</td>
										 <td><input disabled type="number" name="yjcgsdsj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td rowspan="3">同级竞赛、调考优秀频次</td>
										 <td>国家级</td>
										 <td>-</td>
										 <td><input disabled type="number" name="tjjspcgjj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td>国网公司（省部）级</td>
										 <td>-</td>
										 <td><input disabled type="number" name="tjjspcsbj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td>省公司（市）级</td>
										 <td>-</td>
										 <td><input disabled type="number" name="tjjspcdsj" class="special-style" /></td>
									 </tr>
									 <!-- 以上为专业成果 -->
									 <tr>
										 <td rowspan="3">X6</td>
										 <td rowspan="3">专业化能力</td>
										 <td colspan="3">高 >=7</td>
										 <td>2</td>
										 <td><input disabled type="radio" name="zyhnl" value="高" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">中 >=5,<7</td>
										 <td>1</td>
										 <td><input disabled type="radio" name="zyhnl" value="中" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">低 <5</td>
										 <td>0.5</td>
										 <td><input disabled type="radio" name="zyhnl" value="低" /></td>
									 </tr>
									 <!-- 以上为专业化能力 -->
									 <tr>
										 <td rowspan="3">X7</td>
										 <td rowspan="3">管理经历</td>
										 <td colspan="3">从事部门、班组、站所负责人经历年限</td>
										 <td>0.25</td>
										 <td><input disabled type="number" name="fzrnx" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">跨单位交流次数</td>
										 <td>0.25</td>
										 <td><input disabled type="number" name="kdwjlcs" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">从事党务工作主要负责人（书记）经历年限</td>
										 <td>0.25</td>
										 <td><input disabled type="number" name="dwgzfzrnx" class="special-style" /></td>
									 </tr>
									 <!-- 以上为管理经历 -->
									 <tr>
										 <td rowspan="5">X8</td>
										 <td rowspan="5">创新创效</td>
										 <td rowspan="5">创新项目奖项名次或发表创新理论论文被收录或获奖</td>
										 <td>国家级</td>
										 <td rowspan="4">获第一名或一等奖，加权重1.1</td>
										 <td>2</td>
										 <td><input disabled type="checkbox" name="cxcxgjj" /></td>
									 </tr>
									 <tr>
										 <td>国网公司（省部）级</td>
										 <td>1</td>
										 <td><input disabled type="checkbox" name="cxcxsbj" /></td>
									 </tr>
									 <tr>
										 <td>省公司（市）级</td>
										 <td>0.5</td>
										 <td><input disabled type="checkbox" name="cxcxdsj" /></td>
									 </tr>
									 <tr>
										 <td>地市公司（县）级</td>
										 <td>0.1</td>
										 <td><input disabled type="checkbox" name="cxcxxj" /></td>
									 </tr>
									 <tr>
										 <td>县公司级创新工作室项目孵化</td>
										 <td>取项目前三名计分</td>
										 <td>0.1</td>
										 <td><input disabled type="checkbox" name="cxcxxzj" /></td>
									 </tr>
									 <!-- 以上为创新创效 -->
									 <tr>
										 <td>X9</td>
										 <td>三年岗位竞聘频次</td>
										 <td colspan="3">近三年参加岗位竞聘次数（减分项）</td>
										 <td>0.1</td>
										 <td><input disabled type="number" name="jsngwjppc" class="special-style" /></td>
									 </tr>
									 <!-- 以上为岗位竞聘 -->
									 <tr>
										 <td rowspan="10">X10</td>
										 <td rowspan="10">三年荣誉情况</td>
										 <td rowspan="5">综合类表彰</td>
										 <td colspan="2">国家级</td>
										 <td>1</td>
										 <td><input disabled type="number" name="zhlbzgjj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">国网公司（省部）级</td>
										 <td>0.8</td>
										 <td><input disabled type="number" name="zhlbzsbj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">省公司（市）级</td>
										 <td>0.5</td>
										 <td><input disabled type="number" name="zhlbzdsj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">地市公司（县）级</td>
										 <td>0.1</td>
										 <td><input disabled type="number" name="zhlbzxj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">县公司级</td>
										 <td>0.05</td>
										 <td><input disabled type="number" name="zhlbzzj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td rowspan="5">专业、专项类表彰</td>
										 <td colspan="2">国家级</td>
										 <td>0.8</td>
										 <td><input disabled type="number" name="zylbzgjj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">国网公司（省部）级</td>
										 <td>0.5</td>
										 <td><input disabled type="number" name="zylbzsbj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">省公司（市）级</td>
										 <td>0.1</td>
										 <td><input disabled type="number" name="zylbzdsj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">地市公司（县）级</td>
										 <td>0.05</td>
										 <td><input disabled type="number" name="zylbzxj" class="special-style" /></td>
									 </tr>
									 <tr>
										 <td colspan="2">县公司级</td>
										 <td>0.025</td>
										 <td><input disabled type="number" name="zylbzzj" class="special-style" /></td>
									 </tr>
									 <!-- 以上为荣誉情况 -->
									 <tr>
										 <td rowspan="5">X11</td>
										 <td rowspan="5">人才称号</td>
										 <td colspan="3">国家级：万人计划人选、百千万人才国家级人选、国家级突出贡献中青年专家等</td>
										 <td>3</td>
										 <td><input disabled type="checkbox" name="rcchgjj" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">国网公司（省部）级</td>
										 <td>2</td>
										 <td><input disabled type="checkbox" name="rcchsbj" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">省公司（市）级</td>
										 <td>1</td>
										 <td><input disabled type="checkbox" name="rcchdsj" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">地市公司（县）级</td>
										 <td>0.5</td>
										 <td><input disabled type="checkbox" name="rcchxj" /></td>
									 </tr>
									 <tr>
										 <td colspan="3">县公司级</td>
										 <td>0.1</td>
										 <td><input disabled type="checkbox" name="rcchzj" /></td>
									 </tr>
									 <!-- 以上为人才称号 -->
									 <tr>
										 <td>X12</td>
										 <td>三年工作差错频次</td>
										 <td colspan="3">近三年工作差错频次（减分项）</td>
										 <td>0.01</td>
										 <td><input disabled type="number" name="jsngzccpc" class="special-style" /></td>
									 </tr>
									 </tbody>
								 </table>
							 </form>
						 </div>
<!--						 <div class="m-t-30">-->
<!--							 <button id="id-calc-model" type="button" class="btn btn-info" style="width:100%">精准适配分析：一键生成特定人岗适配模型</button>-->
<!--						 </div>-->
					 </div>
                </div>
            </div>
        </div>
        <div class="col-lg-5">
            <div class="card">
                <div id="id-standard-diagram" class="card-body">
                 <h4 class="card-title">适岗模型<!-- ：XXX通用岗位 --></h4>
                 <div class="card-content m-t-20">
                     <div id="id-special-raddr" style="height: 420px"></div>

                        <table id="id-special-table" class="table table-bordered content-center m-t-20"  cellspacing="0" width="100%">
                            <thead>
                                <tr>
                                    <th>&nbsp;</th>
                                    <th>专业性<br/>(Z)</th>
                                    <th>创效性<br/>(C)</th>
                                    <th>可塑性<br/>(P)</th>
                                    <th>稳定性<br/>(W)</th>
                                    <th>相容性<br/>(X)</th>
                                    <th>适应性<br/>(S)</th>
                                </tr>
                            </thead>
                         </table>
                 </div>
                </div>
            </div>
        </div>
    </div>
    <!-- End PAge Content -->
</div>
<!-- End Container fluid  -->
</@panel.body>
<@panel.footer>
<script type="text/javascript" src="${ROOT}/mind/js/plugins/alangyun-filterbox.js"></script>
<script type="text/javascript" src="${ROOT}/mind/js/lib/datatables/datatables.min.js"></script>
<script type="text/javascript" src="${ROOT}/mind/js/lib/datatables/jquery.dataTables.zh-CN.js"></script>
<script type="text/javascript" src="${ROOT}/mind/js/lib/format/jquery.formatter.js"></script>
<script type="text/javascript" src="${ROOT}/mind/js/lib/echart/echarts.min.5.4.0.js"></script>
<script type="text/javascript">
	document.getElementById('id-export-file').addEventListener('click', function() {
		// Ensure echarts charts have finished rendering
		setTimeout(() => {
			var charts = document.querySelectorAll('canvas');
			charts.forEach(chart => {
				var dataURL = chart.toDataURL();
				var imgTag = '<img src="' + dataURL + '" width="500" />';
				chart.insertAdjacentHTML('beforebegin', imgTag);
				chart.style.display = 'none'; // Hide the original canvas
			});

			// Create a temporary container for the export
			var exportContainer = document.createElement('div');
			exportContainer.id = 'export-container';
			exportContainer.style.width = '100%';

			// Clone ECharts charts
			var chartContainer = document.getElementById('id-special-raddr').cloneNode(true);
			exportContainer.appendChild(chartContainer);

			// Clone user table and add border class
			var clonedTables = document.getElementById('id-special-table').cloneNode(true);
			var clonedTable = document.getElementById('id-standard-table').cloneNode(true);

// 直接添加内联样式到每个th和td元素
			clonedTables.querySelectorAll('th, td').forEach(function(cell) {
				cell.style.border = '1px solid #000';
				cell.style.borderCollapse = 'collapse'; // 注意：borderCollapse是CSS属性，不能作为内联样式设置，但这里为了示例而写
				cell.style.textAlign = 'center';
			});
			exportContainer.appendChild(clonedTables);
			clonedTable.querySelectorAll('th, td').forEach(function(cell) {
				cell.style.border = '1px solid #000';
				cell.style.borderCollapse = 'collapse'; // 注意：borderCollapse是CSS属性，不能作为内联样式设置，但这里为了示例而写
				cell.style.textAlign = 'center';
			});
			exportContainer.appendChild(clonedTable);


			// Convert the export container's HTML to a Word document
			var htmlHeader = `
          <!DOCTYPE html>
          <html>
          <head>
            <style>
               table, th, td {
                   border: 1px solid #000;
                   text-align: center;
                   border-collapse: collapse;
               }
            </style>
          </head>
          <body>`;
			var htmlFooter = `
          </body>
          </html>`;
			var htmlContent = htmlHeader + exportContainer.innerHTML + htmlFooter;

			var blob = new Blob([htmlContent], { type: 'application/msword' });
			var url = URL.createObjectURL(blob);
			var a = document.createElement('a');
			a.href = url;
			a.download = '制定通用人岗适配模型.doc';
			a.click();
			URL.revokeObjectURL(url);

			// Clean up by removing the temporary container
			exportContainer.remove();

			// Revert changes made to the document for export
			charts.forEach(chart => {
				chart.previousSibling && chart.previousSibling.remove();
				chart.style.display = 'block'; // Restore the original canvas
			});
		}, 1000); // Adjust the timeout as needed to ensure charts have rendered
	});
  $(document).ready(function(){
	  $(".btn-click-bind").click(function() {
		  var val = $(this).data("sign");
		  var ctx = "/w/prof";
		  if(12===val){
			  ctx = "/w/prof12";
		  }else if(21===val){
			  ctx = "/w/prof21";
		  }else if(22===val){
			  ctx = "/w/prof22";
		  }
		  window.location.href="${ROOT}" + ctx;
	  });

	var rdChart = echarts.init(document.getElementById("id-special-raddr"));
	  //分析图
	var dataToChart = function(mydata){

		  var max=[];
		  var min=[];
		  max.push(mydata.z);
		  max.push(mydata.s);
		  max.push(mydata.x);
		  max.push(mydata.w);
		  max.push(mydata.p);
		  max.push(mydata.c);
		  min.push(mydata.z / 2);
		  min.push(mydata.s / 2);
		  min.push(mydata.x / 2);
		  min.push(mydata.w / 2);
		  min.push(mydata.p / 2);
		  min.push(mydata.c / 2);

	    option = {
		        color: ["#58a2eb", "#ef5350"],
		        tooltip : {
		            trigger: 'item'
		        },
		        legend: {
		            show: false
		        },
		        polar : [
		            {
		                indicator : [
		                    { text: '专业性(Z)', max: 10},
		                    { text: '适应性(S)', max: 10},
		                    { text: '相融性(X)', max: 10},
		                    { text: '稳定性(W)', max: 10},
		                    { text: '可塑性(P)', max: 10},
		                    { text: '创效性(C)', max: 10}
		                ]
		            }
		        ],
		        calculable : true,
		        series : [
		            {
		                type: 'radar',
		                data : [{
		    	    		name: "标准",
		    	    		label: {
		    	    			show: false,
		    	    			formatter: function(params){
		    	    				return $.formatFloat(params.value, 2);
		    	    			}
		    	    		},
		    	    		areaStyle: {
		    	    			color: "#58a2eb"
		    	    		},
		    	    		value: max
		    		   	 },{
		    		    		name: "下限",
		    		    		label: {
		    		    			show: false,
		    		    			formatter: function(params){
		    		    				return $.formatFloat(params.value, 2);
		    		    			}
		    		    		},
		    		    		areaStyle: {
		    		    			color: "#ef5350"
		    		    		},
		    		    		value:min
		    		    }
		                ]
		            }
		        ]
	    };

	    if (option && typeof option === "object") {
	        rdChart.setOption(option, false);
	    }
	    window.addEventListener('resize', rdChart.resize);
	}

	var $table = null;
	var dataToTableView = function(mydata){
		if(!mydata){
			return;
		}

		  var max={
				  name: '标准值',
				  z: mydata.z,
				  s: mydata.s,
				  x: mydata.x,
				  w: mydata.w,
				  p: mydata.p,
				  c: mydata.c
		  };
		  var min={
				  name: '下限值',
				  z: mydata.z / 2,
				  s: mydata.s / 2,
				  x: mydata.x / 2,
				  w: mydata.w / 2,
				  p: mydata.p / 2,
				  c: mydata.c / 2
		  };

		if($table) {
			$table.fnClearTable();
			$table.fnDestroy();
		}

		$table = $("#id-special-table").dataTable({
		    "ordering":false,
		    "searching": false,
		    "bFilter":false,
		    "info": false,
		    "paging": false,
		    'bAutoWidth':false,
		    "bDestroy" : true,
		    "aoColumns": [
		    	{'mData': 'name', sWidth: '100px', defaultContent: '' },
		    	{'mData': 'z', sWidth: '100px', defaultContent: '', render: function(value){return $.formatFloat(value, 2)} },
		    	{'mData': 'c', sWidth: '100px', defaultContent: '', render: function(value){return $.formatFloat(value, 2)} },
		    	{'mData': 'p', sWidth: '100px', defaultContent: '', render: function(value){return $.formatFloat(value, 2)} },
		    	{'mData': 'w', sWidth: '100px', defaultContent: '', render: function(value){return $.formatFloat(value, 2)} },
		    	{'mData': 'x', sWidth: '100px', defaultContent: '', render: function(value){return $.formatFloat(value, 2)} },
		    	{'mData': 's', sWidth: '100px', defaultContent: '', render: function(value){return $.formatFloat(value, 2)} }
		    ],
		    "data":[max, min]
		});
		$table.fnDraw();
	};


    // 导出事件绑定
    // $('#id-export-file').click(function(){
    // 	var pdfCanvas = $.fn.pdfcanvas({
    // 		title: '通用人岗适配模型',
    // 		direct: 'p',
    // 		keywords: '单位和部门：；岗位类别：'
    // 	})
    // 	pdfCanvas.addDom(document.getElementById("id-standard-diagram"));
    // 	pdfCanvas.addDom(document.getElementById("id-standard-table"));
    // 	pdfCanvas.print();
	//
    // });

    //初始化过滤面板
    $.post('${ROOT}/w/treeNav',function(data, status){
    	if(data.code==="ok"){
			$.fn.filterBox({
				data: data.data,
				onsubmit: function(form, data){
					console.log(data);
					$.ajax({
						url: '${ROOT}/w/updStandard?' + data,
						method: 'post',
						success: function(data1) {
							if(data1.code==="ok"){
								//初始提取数据
								$.post('${ROOT}/w/standardM',function(data2, status){
								if(data2.code==="ok"){
									$('#id-model-form').formEdit(data2.data);
									dataToChart(data2.data);
									dataToTableView(data2.data);
								}
							});
							}
						}
					});
				}
			})
    	}
    });


    //初始提取数据
    $.post('${ROOT}/w/standardM',function(data, status){
    	if(data.code==="ok"){
			$('#id-model-form').formEdit(data.data);
			dataToChart(data.data);
			dataToTableView(data.data);
    	}
    });

  });
</script>
</@panel.footer>
</#escape>